// 数组的解构
const arr = [1,2,3]
// const f = arr[0]
// const b = arr[1]
// const c = arr[2]

// const [f, b, c] = arr
// console.log(f,b,c)

// const [ , , c] = arr
// console.log(c)

// const [ f, ...c] = arr
// console.log(c)

// const [f, b] = arr
// console.log(f,b)

// const [f, b, c, d='more'] = arr
// console.log(f,b,c,d)

const path = 'foo/part/ccc'
// const tmp = path.split('/')
// const root = tmp[1]
// console.log(root)
const [,root] = path.split('/')
console.log(root)